package com.github.prontera.domain.enums;

import com.github.prontera.common.mybatis.handler.CodeEnum;

public enum ConsumeSmallTypeEnum implements CodeEnum<ConsumeSmallTypeEnum> {

	LOOK_VEDIO(0, "查看视频"), VIEW_COTERIE(1, "查看圈子"), SYSTEM_GIVE(2, "系统赠送"),SYSTEM_DEDUCTIBLE(3, "系统抵扣"), LOOK_WECHAT(4, "查看微信"), RECHARGE_BEAN(5, "充值唐豆")
	, TAKE_ACTIVITY(6, "参与活动"), RECHARGE_BALANCE(7, "充值余额"), BUY_VIP(8, "购买VIP"), DEPOSIT(9, "提现押金"),
	SUBORDINATE_BUG_VIP(10, "下线购买VIP"), SUBORDINATE_TALENT(11, "下线出租达人"), ISSSUE_PAY(12, "红包提问"),R_VIEW_COTERIE(13, "圈子被查看"),
	R_BUY_TALEND(14, "达人被消费"),BUY_TALEND(15, "达人消费"),R_LOOK_VEDIO(16, "视频被查看"),RR_LOOK_VEDIO(17, "提问视频被查看"),R_LOOK_WECHAT(18, "微信被查看")
	
	,REFUND_VIP(19, "退VIP"),REFUND_DEPOSIT_AMOUNT(20, "提现"),REFUND_TALEND_ORDER(21, "退达人单"),REGISTER(22, "注册"),BINDES_CARD(23, "绑定银行卡")
	,VISITOR_CLIENT(24, "访问用户"),SIGN_DAY(25, "每日签到"),BUG_TASK(26, "活动保证金")
	
	;

	private int code;
	private String desc;

	private ConsumeSmallTypeEnum(int code, String desc) {
		this.code = code;
		this.desc = desc;
	}

	/**
     * 通过枚举<code>name</code>获取枚举
     */
    public static ConsumeSmallTypeEnum getEnumByCode(Integer code) {
    	if(code==null){
    		return null;
    	}
        for (ConsumeSmallTypeEnum enumm : ConsumeSmallTypeEnum.values()) {
            if (enumm.getCode()==code.intValue()) {
                return enumm;
            }
        }
        return null;
    }
    
	@Override
	public int getCode() {
		return code;
	}

	public String getDesc() {
		return desc;
	}
	
}
